package at.fhooe.mc.master.clc.server.dataaccess;

import at.fhooe.mc.master.clc.server.dataaccess.dao.ITestableDao;
import at.fhooe.mc.master.clc.server.domain.ITestable;
import at.fhooe.mc.master.clc.shared.domain.FrameworkID;

public abstract class MetricsDAOFactory
{
	
	public abstract ITestableDao getTestableDao();
	
	public static MetricsDAOFactory getDAOFactory(FrameworkID type)
	{
		switch (type)
			{
			case OBJECTIFY:
				return new ObjectifyMetricsDAOFactory();
			case JDO:
				return new JdoMetricsDAOFactory();
			case JPA:
				return new JpaMetricsDAOFactory();
			case NATIVE:
				return new NativeMetricsDAOFactory();
			default:
				return null;
			}
	}
}
